
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fopenmp")

include_directories("${CMAKE_CURRENT_LIST_DIR}/../include")

macro(ncnn_add_example name)
    add_executable(${name} ${name}.cpp)
    target_include_directories(${name} PRIVATE ${OpenCV_INCLUDE_DIRS})
    target_link_libraries(${name} PRIVATE ncnn ${OpenCV_LIBS})
endmacro()

# hello test
ncnn_add_example(hello)

# Mat test
ncnn_add_example(MatTest)

ncnn_add_example(opencvEnv)

ncnn_add_example(MatRelease)

ncnn_add_example(logistic)

# alexnet
ncnn_add_example(alexnet)

#测试opencv和ncnn的warpAffine函数的执行时间performance
ncnn_add_example(perf_warpAffine)
